import request from '@/utils/request'
// 获取产线列表
export function productionlineList(query) {
    return request({
      url: '/mes/ipqc/base/line/list',
      method: 'get',
      params: query
    })
  }
//table数据请求
export function getData(query) {
    return request({
      url: '/mes/ipqc/base/groupList',
      method: 'get',
      params: query
    })
}

//日报表页面 
//根据报表id查询头部form
export function getForm(reportId) {
  return request({
    url: '/mes/ipqc/base/' + reportId,
    method: 'get'
  })
}

//table1数据请求
export function gettableData(query) {
  return request({
    url: '/mes/ipqc/base/inspection/head/list',
    method: 'get',
    params: query
  })
}

//table2数据请求
export function getTimeData(query) {
  return request({
    url: '/mes/ipqc/inspection/detail/listByInspectioId',
    method: 'get',
    params: query
  })
}

//查询巡检sn码集合接口
export function snCodeListByInspectioIds(data) {
  return request({
    url: '/mes/ipqc/inspection/detail/snCodeListByInspectioIds',
    method: 'post',
    data
  })
}

//日报表导出
export function dailyReportTexport(data) {
  return request({
    url: '/mes/ipqc/inspection/detail/export',
    method: 'post',
    data,
    responseType: 'blob'
  })
}
  
//ipqc巡检列表导出
export function tableExport(query) {
  return request({
    url: '/mes/ipqc/base/export',
    method: 'get',
    params: query,
    responseType: 'blob'
  })
}